package com.my.ext.mapper;

import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

import com.my.ext.entity.User;

@Repository
public interface UserMapper {

	User findUser(@Param("openid") String openid);
	
	int saveUserAsFirst(@Param("user") User u);
	
	int updateUser(@Param("org") int org, @Param("group") int group, @Param("name") String name,@Param("code")String code, @Param("openid")String openid);
	
	int updateSessionKey(@Param("openid")String openid, @Param("sessionKey")String sessionKey);
	
	String getSessionKey(@Param("openid") String openid);
	
}
